import EventManager from "./eventManager";

const {ccclass, property} = cc._decorator;

@ccclass
export default class View extends cc.Component{
    public on(type:string,callback:Function,target:any){
        EventManager.instance().on(type,callback,target)
    }
    public emit(type:string,...args:any){
        EventManager.instance().emit(type,...args)
    }
    public off(type:string,callback:Function,target:any){
        EventManager.instance().off(type,callback,target)
    }
}